﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Security.Cryptography;
using System.IO;

namespace _1___SHA1
{
    class Program
    {
        

        static void Main(string[] args)
        {
            using (FileStream inFile = new FileStream("input.bin", FileMode.Open))
            {
                byte[] buf = new byte[inFile.Length];
                int bytesRead = inFile.Read(buf, 0, buf.Length);
                SHA1 sha = new SHA1CryptoServiceProvider();
                byte[] result = sha.ComputeHash(buf);
                Console.WriteLine(Convert.ToBase64String(result));
            }
        }
    }
}
